package com.electric.electric.controller;

import com.electric.electric.POJO.DTO.EvaluationRequestDTO;
import com.electric.electric.POJO.VO.EvaluationResponseVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*;
import com.electric.electric.service.EvaluationService;

@RestController
@RequestMapping("/api/evaluation")
public class EvaluationController {

    @Autowired
    private EvaluationService evaluationService;
    @PostMapping("/calculate")
    public ResponseEntity<EvaluationResponseVO> calculateEvaluation(@RequestBody EvaluationRequestDTO request) {
        EvaluationResponseVO response = evaluationService.calculateEvaluation(request);
        return ResponseEntity.ok(response);
    }
}